<!DOCTYPE html>
<html lang="zh-CN">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="initial-scale=1, user-scalable=0, minimum-scale=1.0, maximum-scale=1.0" />
  <title>表单</title>
  <style>
    html,
    body {
      margin: 0;
      padding: 0;
      height: 100%;
      background: #dadada;
    }
    
    header {
      height: 44px;
      line-height: 44px;
      text-align: center;
      background: #da020c;
      color: #fff;
    }
    
    h1 {
      margin: 0;
      padding: 0;
      font-size: 18px;
      font-weight: normal;
    }
    
    header>a {
      height: 34px;
      line-height: 34px;
      position: absolute;
      top: 5px;
      left: 10px;
    }
    
    #warning {
      height: 64px;
      padding: 10px;
      font-size: 14px;
      line-height: 1.3;
      color: red;
    }
    
    #wrapper {
      position: absolute;
      top: 44px;
      bottom: 44px;
      width: 100%;
    }
    
    #scroller {
      margin: 0;
      padding: 0;
      background: #fff;
    }
    
    table {
      width: 100%;
      line-height: 42px;
    }
    
    table tr td:nth-child(1) {
      width: 100px;
      text-align: right;
    }
    
    input,
    textarea {
      border: 1px solid #ddd;
      width: 90%;
      padding: 4px 0;
    }
    
    textarea {
      height: 50px;
    }
    
    #footer {
      position: absolute;
      bottom: 0;
      left: 0;
      width: 100%;
      height: 44px;
      background: #aaa;
    }
    
    #footer input {
      float: left;
      width: 70%;
      margin-left: 5%;
      height: 20px;
      margin-top: 8px;
    }
    
    #footer input[type='button'] {
      width: 12%;
      float: right;
      margin-right: 5%;
      margin-top: 8px;
      height: 30px;
      padding: 0;
    }
  </style>
</head>

<body>
  <header>
    <h1>表单</h1>
    <a onclick="javascript:history.back()">&lt;返回</a>
  </header>
  <div id="wrapper">
    <div id="scroller">
      <table>
        <tr>
          <td>姓名：</td>
          <td><input></td>
        </tr>
        <tr>
          <td>年龄：</td>
          <td><textarea></textarea></td>
        </tr>
        <tr>
          <td>户籍：</td>
          <td><input></td>
        </tr>
        <tr>
          <td>性别：</td>
          <td><textarea></textarea></td>
        </tr>
        <tr>
          <td>学校：</td>
          <td><input></td>
        </tr>
        <tr>
          <td>职业：</td>
          <td><textarea></textarea></td>
        </tr>
        <tr>
          <td>兴趣：</td>
          <td><input></td>
        </tr>
        <tr>
          <td>爱好：</td>
          <td><textarea></textarea></td>
        </tr>
      </table>
    </div>
  </div>
  <div id="footer">
    <input type="text">
    <input type="button" value="提交">
  </div>

  <script src="../../vendor/fastclick.js"></script>
  <script src="../../src/jroll.js"></script>
  <script src="./jroll-fixedinput.js"></script>
  <script>
    var jroll = new JRoll("#wrapper");
    jroll.fixedinput(10, true);

    FastClick.attach(document.body);
  </script>
</body>

</html>